﻿@{
    ViewBag.Title = "BindOrReg";
}

<div class="container-fluid" style="width:50%;margin: 0 auto;padding:0px;float:left;">
<form action="/login/doregister" class="form-horizontal" method="post" novalidate="novalidate">    <div>
        <fieldset>
            <legend>帐户信息</legend> 
            <div class="control-group">
              <label class="control-label">用户名：</label>
                <div class="controls">
                <input data-val="true" data-val-remote="用户名已被注册！" data-val-remote-additionalfields="*.UserName" data-val-remote-url="/Action/User/IsExsts" data-val-required="用户名 字段是必需的。" id="UserName" name="UserName" type="text" value="@ViewBag.user["uname"]">
                <p class="help-block"><span class="field-validation-valid" data-valmsg-for="UserName" data-valmsg-replace="true"></span></p>
              </div>
            </div>
            <div class="control-group">
              <label class="control-label">电子邮件地址：</label>
                <div class="controls">
                <input data-val="true" data-val-regex="请输入正确的email地址" data-val-regex-pattern="\w+([-+.']\w+)*@@\w+([-.]\w+)*\.\w+([-.]\w+)*" data-val-remote="电子邮件地址已被注册！" data-val-remote-additionalfields="*.Email" data-val-remote-url="/Action/User/IsMailExsts" data-val-required="电子邮件地址 字段是必需的。" id="Email" name="Email" type="text" value="">
                <p class="help-block"><span class="field-validation-valid" data-valmsg-for="Email" data-valmsg-replace="true"></span></p>
              </div>
            </div>

            <div class="control-group">
              <label class="control-label">密码：</label>
                <div class="controls">
                <input data-val="true" data-val-regex="密码必须为6-20位" data-val-regex-pattern="[一-龥0-9a-zA-Z_]{6,20}" data-val-required="密码 字段是必需的。" id="Password" name="Password" type="password">
                <p class="help-block"><span class="field-validation-valid" data-valmsg-for="Password" data-valmsg-replace="true"></span></p>
              </div>
            </div>

            <div class="control-group">
              <label class="control-label">确认密码：</label>
                <div class="controls">
                <input data-val="true" data-val-equalto="密码和确认密码不匹配。" data-val-equalto-other="*.Password" id="ConfirmPassword" name="ConfirmPassword" type="password">
                <p class="help-block"><span class="field-validation-valid" data-valmsg-for="ConfirmPassword" data-valmsg-replace="true"></span></p>
              </div>
            </div>

            <div class="form-actions">
            <button type="submit" class="btn btn-primary">注册</button>
             <input type="hidden" name="header" value="@ViewBag.user["header"]" />
          </div>
        </fieldset>
    </div>
</form></div>

<div class="container-fluid" style="width:50%;margin: 0 auto;padding:0px;float:left;">
  <form class="form-horizontal" action="/login/dologin" method="post" novalidate="novalidate">
  <fieldset>
    <legend>登录</legend>
    <div class="control-group">
      <label class="control-label" for="input01">登录名：</label>
      <div class="controls">
        <input class="input-xlarge" data-val="true" data-val-required="用户名 字段是必需的。" id="UserName" name="UserName" type="text" value="">
        <p class="help-block"><span class="field-validation-valid" data-valmsg-for="UserName" data-valmsg-replace="true"></span></p>
      </div>
    </div>
    <div class="control-group">
      <label class="control-label" for="input01">登录密码：</label>
      <div class="controls">
        <input class="input-xlarge" data-val="true" data-val-required="密码 字段是必需的。" id="Password" name="Password" type="password">
        <p class="help-block"><span class="field-validation-valid" data-valmsg-for="Password" data-valmsg-replace="true"></span></p>
      </div>
    </div>
    <div class="control-group">
      <div class="controls">
        <input data-val="true" data-val-required="记住我? 字段是必需的。" id="RememberMe" name="RememberMe" type="checkbox" value="true"><input name="RememberMe" type="hidden" value="false"> <span> 保存状态</span>
        <p class="help-block"></p>
      </div>
    </div>
     <div class="form-actions">
            <button type="submit" class="btn btn-primary">登录</button>
         <input type="hidden" name="header" value="@ViewBag.user["header"]" />
      </div>
  </fieldset>
</form>
</div>
@section scripts{
    @Scripts.Render("~/js/jqueryval")
}
